< Prev(J) / Next(K) > / View :

Filename: /text/sbasic/shared/03103200.xhp

(section: optionbase) (bookmark: bm_id3155805)
Option Base statement

Option Base ステートメント

Option Base Statement [Runtime]
Option Base ステートメント [実行時](hd_id3155805.1)

Defines the default lower boundary for arrays as 0 or 1.
配列のインデックス範囲について、デフォルトで適用される下限値を 0 ないし 1 のいずれかに設定します。(par_id3147242.2)

(/section: optionbase)

Syntax:
構文:(hd_id3150771.3)

Option Base { 0 | 1}
Option Base { 0 | 1}(par_id3147573.4)

Parameters:
パラメータ:(hd_id3145315.5)

Warning Icon 警告マーク This statement must be added before the executable program code in a module.
このステートメントを記述するプログラム中の位置は、モジュール内のすべての実行コードよりも前にする必要があります。(par_id3147229.6)

Example:
例:(hd_id3150870.7)

option Base 1
option Base 1(par_id3152921.8)

Sub ExampleOptionBase
Sub ExampleOptionBase(par_id3153192.10)

Dim sVar(20) As String
Dim sVar(20) As String(par_id3149561.11)

msgbox LBound(sVar())
msgbox LBound(sVar())(par_id3153770.12)

end sub
end sub(par_id3159153.13)


< Prev / Next >